const Service = require('egg').Service
const { Op } = require("sequelize");

class SwiperService extends Service{
  async getSwiperList(ids) {
    const {ctx} = this
    // console.log(ids)
    // let id = JSON.parse(ids)
    return await ctx.model.Image.findAll({
      where: {
        id: { 
          [Op.in]: ids
        }
      }
    })
  }
}

module.exports = SwiperService